*,
*::after,
*::before {
	box-sizing: border-box;
}

:root {
	font-size: 14px;
}

#body {
	margin: 0;
	--color-text: #e5e3e0;
	--color-bg: #000;
	--color-link: #e5e3e0;
	--color-link-hover: #fff;
	--color-title: #faedba;
	--color-bg-item: #282b27;
	--color-menu-tag: #f0b579;
	--color-menu-link: #fff;
	--color-menu-link-hover: #f0b579;
	--font-menu-link: rigatoni, sans-serif;
	--font-weight-menu-link: 400;
	--font-size-menu-link: 5vw;
	--clip-1: polygon(37% 15%, 63% 15%, 63% 85%, 37% 85%);
	color: var(--color-text);
	background-color: var(--color-bg);
	font-family: soleil, Futura, "Trebuchet MS", Arial, sans-serif;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

.demo-2 {
	--color-text: #fff;
	--color-bg: #000;
	--color-link: #e5e3e0;
	--color-link-hover: #fff;
	--color-title: #faedba;
	--color-bg-item: #282b27;
	--color-menu-tag: #f0b579;
	--color-menu-link: #fff;
	--color-menu-link-hover: #f0b579;
	--font-menu-link: poynter-oldstyle-display, serif;
	--font-weight-menu-link: 400;
	--font-size-menu-link: 4vw;
	--clip-1: polygon(10% 0, 25% 0%, 30% 60%, 50% 35%, 70% 60%, 75% 0, 90% 0, 80% 100%, 50% 60%, 20% 100%);
}

.demo-3 {
	--color-text: #fff;
	--color-bg: #000;
	--color-link: #6c6c6c;
	--color-link-hover: #fff;
	--color-title: #737476;
	--color-bg-item: #282b27;
	--color-menu-tag: #f0f0f0;
	--color-menu-link: #e88e41;
	--color-menu-link-hover: #fff;
	--font-menu-link: rigatoni, serif;
	--font-weight-menu-link: 400;
	--font-size-menu-link: 5vw;
	--clip-1: polygon(50% 0%, 20% 100%, 80% 100%);
}

.demo-4 {
	--color-text: #fff;
    --color-bg: #000;
    --color-link: #e5e3e0;
    --color-link-hover: #fff;
    --color-title: #ffffff;
    --color-bg-item: #282b27;
    --color-menu-tag: #ffffff;
    --color-menu-link: #d05d3b;
    --color-menu-link-hover: #ffffff;
	--font-menu-link: latienne-pro, serif;
	--font-weight-menu-link: 700;
	--font-size-menu-link: 5vw;
	--clip-1: circle(41.9% at 19% 99%);
	--clip-2: circle(16.2% at 74% 38%);
}

/* Page Loader */
.js .loading::before,
.js .loading::after {
	content: '';
	position: fixed;
	z-index: 1100;
}

.js .loading::before {
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: var(--color-bg);
}

.js .loading::after {
	top: 50%;
	left: 50%;
	width: 60px;
	height: 60px;
	margin: -30px 0 0 -30px;
	border-radius: 50%;
	opacity: 0.4;
	background: var(--color-link);
	animation: loaderAnim 0.7s linear infinite alternate forwards;
}

@keyframes loaderAnim {
	to {
		opacity: 1;
		transform: scale3d(0.5,0.5,1);
	}
}

a {
	text-decoration: none;
	color: var(--color-link);
	outline: none;
}

a:hover,
a:focus {
	color: var(--color-link-hover);
	outline: none;
}

.main {
	position: relative;
}

.frame {
	padding: 3rem 5vw;
	position: relative;
	z-index: 1000;
}

.frame__title {
	font-size: 1rem;
	margin: 0;
}

.frame__header--grid {
	width: fit-content;
	display: grid;
	grid-template-columns: auto auto;
}

.frame__header--grid::before,
.frame__header--grid::after {
	content: '---';	
}

.frame__header--grid::before {
	grid-area: 1 / 1 / 2 / 3;
}

.frame__header {
	margin: 0;
}

.frame__header dd {
	margin: 0 0 0 0.5rem;
}

.frame__header dd a {
	text-decoration: underline;
}

.frame__header dd a:hover,
.frame__header dd a:focus {
	text-decoration: none;
}

.frame__pagetitle {
	font-size: 1rem;
	margin: 0 0 1rem;
	font-weight: 600;
	color: var(--color-title);
}

.frame__demos a:not(:last-child) {
	margin-right: 1rem;
}

.frame__demos {
	margin: 1rem 0;
}

.frame__demo--current,
.frame__demo--current:hover {
	color: var(--color-text);
}

.screens, 
.screen__item, 
.screen {
	top: 0;
	position: absolute;
	width: 100%;
	height: 100%;
	min-height: 100vh;
}

.screen__item {
	opacity: 0;
	background: var(--color-bg-item);
	z-index: 1;
}

.screen__item:first-child {
	opacity: 1;
	z-index: 100;
}

.screen {
	background-repeat: no-repeat;
	background-position: 50% 50%;
	background-size: cover;
	background-image: var(--bg-img);
	will-change: opacity;
}

.screen--full {
	opacity: 0.6;
	will-change: transform;
}

.screen--clip-1 {
	clip-path: var(--clip-1);
}

.screen--clip-2 {
	clip-path: var(--clip-2);
}

.content {
	padding: 2rem;
	position: relative;
	z-index: 100;
}

.menu {
	display: flex;
	flex-direction: column;
	-webkit-touch-callout: none;
	-webkit-user-select: none;
	-moz-user-select: none;
	-ms-user-select: none;
	user-select: none;
}

.menu__item {
	display: inline-block;
	text-align: left;
	margin: 2vh 0;
}

.menu__item-tag {
	color: var(--color-menu-tag);
}

.menu__item-link {
	color: var(--color-menu-link);
	font-family: var(--font-menu-link);
	font-weight: var(--font-weight-menu-link);
	font-size: 3rem;
	line-height: 1;
	display: block;
	cursor: pointer;
	//transition: color 0.2s;
}

.menu__item-link:hover,
.menu__item-link:focus {
	color: var(--color-menu-link-hover);
}

@media screen and (min-width: 53em) {
	body {
		overflow: hidden;
	}
	.frame {
		position: fixed;
		text-align: left;
		z-index: 1000;
		top: 0;
		left: 0;
		display: grid;
		align-content: space-between;
		width: 100%;
		max-width: none;
		height: 100vh;
		padding: 3rem 4rem;
		pointer-events: none;
		grid-template-columns: 30% 40% 30%;
		grid-template-rows: auto auto auto;
		grid-template-areas: 'header pagetitle menu'
							'... ... ...'
							'... ... demos';
	}
	.frame__pagetitle {
		grid-area: pagetitle;
		justify-self: center;
	}
	.frame__header {
		grid-area: header;
		justify-self: start;
	}
	.frame__nav a {
		margin: 0 1rem 0 0;
	}
	.frame__demos {
		margin: 0;
		grid-area: demos;
		justify-self: end;
	}
	.frame__menu {
		grid-area: menu;
		justify-self: end;
	}
	.frame a {
		pointer-events: auto;
	}
	.content {
		height: 100vh;
		display: flex;
		justify-content: center;
		align-items: center;
		position: relative;
		z-index: 100;
	}
	.menu {
		margin: 0 auto;
		max-width: 74vw;
		text-align: center;
		display: block;
	}
	.menu__item {
		margin: 3vh 3vw;
	}
	.menu__item-tag {
		margin: 0 0 0 0.25vw;
	}
	.menu__item-link {
		font-size: var(--font-size-menu-link);
	}
}